package com.hadoop.mr.amiudake.distinct;

import java.io.IOException;

import org.apache.hadoop.io.NullWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Reducer;

public class DistinctReduce extends Reducer<Text, Text, Text, Text>{

	@Override
	protected void reduce(Text key, Iterable<Text> value, Reducer<Text, Text, Text, Text>.Context context)
			throws IOException, InterruptedException {
		try {
			System.out.println(key);
			context.write(key, new Text(" "));
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
	
	

}
